package com.jarvan.repository;

import com.jarvan.model.Endorse;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface EndorseRepository extends JpaRepository<Endorse, Integer> {
    List<Endorse> findAllByBuyerIdAndEndorseStatus(Integer buyerId, Integer endorseStatus);
    Endorse findByTicketId(String ticketId);
    Page<Endorse> findAllByEndorseStatus(Integer endorseStatus, Pageable pageable);
}
